<?php
/**
 * 创建人 : Forpastime
 * 创建时间: 2023/4/10 14:45
 * 个人主页 : http://forpastime.com
 */

namespace App\Service;


use App\Model\Aliyunvod;

use Hyperf\Di\Annotation\Inject;
class AlivodService
{
    /**
     * @var Aliyunvod
     * @Inject()
     */
    protected $aliyunvod;

    public function getVodList($where=[],$field='*',$limit=10)
    {
        $field = for_field_str_to_array($field);
        return $this->aliyunvod->getList($where,$field,$limit);
    }

    public function getVodOne($where=[],$field='*')
    {
        $field = for_field_str_to_array($field);
        return $this->aliyunvod->getOne($where,$field);
    }

    public function addVodOne($data)
    {
        return $this->aliyunvod->addOne($data);
    }

    public function editVodOne($id,$data)
    {
        return $this->aliyunvod->editOne($id,$data);
    }

    public function delVodOne($ids)
    {
        return $this->aliyunvod->del($ids);
    }
}